import { post } from '@/request/http'
import store from '@/store'

const url = '/FTKJWLHYPT/bill/'

/**
 * 查询订单列表
 * @param {*} data
 */
export const queryBillAtt = data =>
  post(url + 'queryBillAtt', {
    Data: {
      Parameters: {
        FTKJWLHYPT: {
          fltUuid: store.state.user.FLT_UUID_DX_H,
          attCode: data.code,
          startTime: data.startTime,
          endTime: data.endTime,
          attStatus: data.status,
          source: data.source,
          cmtNo: data.cmtNo,
          billAttStatus: data.billAttStatus
        }
      },
      PageIndex: {
        FTKJWLHYPT: data.index
      },
      PageSize: {
        FTKJWLHYPT: data.size
      }
    }
  })

/**
 * 查询运单列表
 * @param {*} data
 */
export const queryBillWay = data =>
  post(url + 'queryBillWay', {
    Data: {
      Parameters: {
        FTKJWLHYPT: {
          attUuid: data.attId,
          fltUuid: store.state.user.FLT_UUID_DX_H,
          source: data.source
        }
      }
    }
  })
